package com.holly.unit.bpmn.activiti.pojo;

import com.holly.unit.core.pojo.request.BaseRequest;
import com.holly.unit.scanner.api.annotation.field.ChineseDescription;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotNull;

/**
 * 类描述: 创建事件监听
 *
 * @author fxr
 * @version 1.0.0
 * @date 2022/4/26 16:15
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class CreateEventListenerRequest extends BaseRequest{



    @NotNull(message = "流程模型id不能为空", groups = {CreateEventListenerRequest.createEventListener.class})
    @ChineseDescription("流程模型id")
    private String modelId;

    @NotNull(message = "节点对象id不能为空", groups = {CreateEventListenerRequest.createEventListener.class})
    @ChineseDescription("节点对象id")
    private String nodeId;

    @NotNull(message = "事件类型不能为空", groups = {CreateEventListenerRequest.createEventListener.class})
    @ChineseDescription("事件类型")
    private String eventType;

    @NotNull(message = "监听器类型不能为空", groups = {CreateEventListenerRequest.createEventListener.class})
    @ChineseDescription("监听器类型")
    private String listenerType;

    @NotNull(message = "监听类的全路径不能为空", groups = {CreateEventListenerRequest.createEventListener.class})
    @ChineseDescription("监听类的全路径 如：com.holly.listener.DemoListener")
    private String classUrl;
    /**
     * 参数校验分组：禁用 or 启用
     */
    public @interface createEventListener {
    }

}
